package com.bt.lms.ui.page.sys.style.action.btn;

import com.bt.lms.ui.page.sys.style.BtnStyle;
import javafx.event.EventHandler;
import javafx.scene.control.Button;
import javafx.scene.input.MouseEvent;

/**
 * 鼠标释放事件
 */
public class AddBtnReleasedAction implements EventHandler<MouseEvent> {

    /**
     * 按钮
     */
    private final Button button;


    /**
     * 构建事件
     * @param button 要变化的按钮
     */
    public AddBtnReleasedAction(Button button){
        this.button = button;
    }

    /**
     * 事件实现
     *  颜色改变
     * @param event the event which occurred
     */
    @Override
    public void handle(MouseEvent event) {
        BtnStyle.addBtn(button);
    }



}
